package insterface_Demo_d5;
import java.util.ArrayList;

public class ClassManager {
    private ArrayList<Student> students = new ArrayList<>(); //创建学生数据集合
    //调用选择的重写方案
    private StudentOperator studentOperator = new StudentOperatorImpl2();

    public ClassManager() {
        students.add(new Student("迪丽热巴", '女', 100));
        students.add(new Student("古力娜扎", '女', 100));
        students.add(new Student("马尔扎哈", '男', 90));
        students.add(new Student("卡尔扎巴", '男', 60));
    }

    public void printInfo() {
        studentOperator.printAllInfo(students);
    }
    public void prinscore() {
        studentOperator.printAvergeScore(students);
    }
}
